package cn.zj.admin.modules.issues.domain;

import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.index.Indexed;
import org.springframework.data.mongodb.core.mapping.Document;

import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;

/**
 * 角色类
 * @author xi.yang
 * @create 2020-07-08 17:43
 **/
@Document(collection = "system_role")
public class Role implements Serializable {
    @Id
    private String id;
    /**
     * 角色名
     */
    @Indexed
    private String name;
    /**
     * 菜单
     */
    private Set<String> menus = new HashSet<>();
    /**
     * 详细描述
     */
    private String desc;
    /**
     * 创建时间
     */
    private long createTime;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Set<String> getMenus() {
        return menus;
    }

    public void setMenus(Set<String> menus) {
        this.menus = menus;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public long getCreateTime() {
        return createTime;
    }

    public void setCreateTime(long createTime) {
        this.createTime = createTime;
    }
}
